<template>
  <div class="columnFlex">
    <van-row class="listCon">
      <div class="cellContent">
        <div class="bottom">
          <div class="flex">
            <p class="title">
              {{ this.detailInfo.areaProvince }}
            </p>
            <div>
              <div class="content" v-if="this.highLength > 0">
                <div class="left">高风险地区</div>
                <div class="right">
                  <p v-for="high in this.detailInfo.highArea">
                    {{ high }}
                  </p>
                </div>
              </div>
              <div class="content" v-if="this.middleLength > 0">
                <div class="left">中风险地区</div>
                <div>
                  <p v-for="middle in this.detailInfo.middleArea">
                    {{ middle }}
                  </p>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </van-row>
  </div>
</template>

<script>
export default {
  data() {
    return {
      detailInfo: [],
      nucleinAcidData: [],
      fileList: [],
      highLength: 0,
      middleLength: 0,
    };
  },
  methods: {
    // 获取详情数据
    getData(arr = []) {
      this.detailInfo = arr;
      this.highLength = arr.highArea.length;
      this.middleLength = arr.middleArea.length;
    },
    // 文字内容换行转换
    showHTML(text) {
      return text
        ? text.toString().replace(new RegExp("\r\n|\n", "g"), "<br />")
        : "";
    },
  },
};
</script>

<style scoped lang="less">
.listCon .flex {
  display: block;
}
.listCon .cellContent .title {
    font-weight: 800;
    font-size: 20px;
}
.title {
  display: block;
  line-height: 200px;
  padding: 0px 0px 0px 10px;
  color: #333;
  padding-top: 4px;
}
.content {
  margin: 5px;
  background: #fff;
  border-radius: 5px;
  display: flex;
  align-items: center;
  min-height: 100px;
  .left {
    font:bold 15px '微软雅黑';
    writing-mode: vertical-rl;
    width: 9%;
    margin-right: 10px;
  }
  .right {
    width: 90%;
  }
}
</style>
